package bite20220409;

import javax.swing.text.html.HTMLDocument;

interface IShape{
    //成员变量
    //成员方法
    void func();
}

class Shape{
    public void draw(){
        System.out.println("画图形");
    }

}

class Cycle extends Shape{
    @Override
    public void draw() {
        System.out.println("*");;
    }
}

class Triangle extends Shape{
    @Override
    public void draw() {
        System.out.println("triangle");;
    }
}

class Rect extends Shape{
    @Override
    public void draw() {
        System.out.println("rect");;
    }
}

class Test implements IShape {
    @Override
    public void func() {
        System.out.println("aaa");
    }
}

public class Demo1 {
    public static void drawMap(Shape shape){
        shape.draw();
    }

    public static void main(String[] args) {

    }
}
